import React from 'react';
import {
    StyleSheet,
    Text,
    Image,
    View,
    TouchableOpacity,
} from 'react-native';
import {BaseStyle} from "../../../Style/BaseStyle";




export default class IconColumn extends React.Component {
    constructor(props) {
        super(props);
    }
    render() {
        const { iconsArray, goNavigator } = this.props;
        return (
            iconsArray.map((item, index) =>
                <TouchableOpacity onPress={() => goNavigator(item.navigator,item)} key={index}>
                    <View style={styles.oneStyle}>
                        <Image source={item.picture} style={styles.iconStyle} />
                        <Text style={styles.testStyle}>{item.text}</Text>
                    </View>
                </TouchableOpacity>
            )

        )
    }
}
const styles = StyleSheet.create({
    oneStyle: {
        ...BaseStyle.flexColumn,
        paddingVertical: 20
    },
    testStyle: {
        marginTop:BaseStyle.commonPadding10.paddingHorizontal,
        fontSize: 12,
        color: "#333"
    },
    iconStyle: {
        width: 50,
        height: 50,
        borderRadius: 25
    },
})
